package com.example.rabbitmq.rabbit.hello;

import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @author LiYuhang
 * @version 0.1
 * @application
 * @Date 2020/8/19 22:02
 */
@Slf4j
@Component
@RabbitListener(queues = "hello")
public class HelloReceiver {
    @RabbitHandler
    public void process(String hello) {
        log.info("Hello Receiver:{}",hello);
    }
}
